-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rename fail! to panic! #17894
Rename fail! to panic! #17894
Conversation
@steveklabnik Thanks for getting started on this! Another item to add to the list: renaming other uses of |
I am unsure of the changes in |
344b79c
to
624cf28
Compare
Whew, rebased. That sucked. |
Everything in vec looks good to me |
ffffc8d
to
b73820f
Compare
@aturon i'm guessing that that would be 'deprecate and make a new one'? Like the |
Unsure how to rephrase
|
I guess libcore's failure isn't really the same thing? it's like, hardcore failure, right? |
(speaking of src/libcore/failure.rs specifically) |
checking off libsemver because it's already in an external crate |
same for all the other ones which were moved out |
I'm not sure if something got lost in github, but it's not clear what this is referring to? |
The "failure" here is referring to the implementation of |
Oh, and yes, it's fine to focus on doc comments and leave actual function/parameter names to API stabilization. |
Yeah, I was talking about the method and parameter names. |
1f35289
to
60cd1e0
Compare
Whew! Getting there! I've knocked out all the ones that have no messages, so the ones that left all need work. |
b74eeab
to
2ebdae5
Compare
aaaand rebased |
This is amazing... please ping me on IRC when you're done and I'll try to do the final review quickly to avoid further rebasing pain. |
No worries, after the rebase involving the removal of libdebug (imagine how many format strings went from |
I'm guessing i'll be done in a day or two. been working on other stuff too since this is kind of mind-numbing. |
|
27dd8e9
to
992b60e
Compare
In the libcore stuff, I did change the name of the implementation of panic. I left the others alone though /cc @aturon |
Okay! This is ready for a preliminary review, @aturon . This may not currently compile, I haven't been able to test because I'm literally waiting for the internet to be installed in my new place within the next few hours, and I'm not going to download a snapshot over tethering 😉 I'll be able to double check that this actually works once that's set up. |
This now compiles and stuff correctly. Woo! |
OK, this looks basically good, but I've commented on a bunch of places where I think "fail" or "failure" is actually the right term. After that, please squash down to a couple commits, and add a Thanks again! |
Changed fail macro to panic (compatibility with rust-lang/rust#17894)
This in-progress PR implements #17489.
I made the code changes in this commit, next is to go through alllllllll the documentation and fix various things.
# Panics
for panic conditions and# Errors
forResult
s.Anything else to add to the list, @aturon ? I think I should leave the actual functions with names like
slice_or_fail
alone, since you'll get to those in your conventions work?I'm submitting just the code bits now so that we can see it separately, and I also don't want to have to keep re-building rust over and over again if I don't have to 😉
Listing all the bits so I can remember as I go: